package com.homework.collections;

import java.util.ArrayList;

public class simulation_dquqe {
  ArrayList<Object> arrayList = new ArrayList<>();

  void put(Object o) {
    arrayList.add(o);
  }

  void Object_get(int index) {
    System.out.println(arrayList.get(index));
  }

  boolean isEmpty() {
    if (arrayList.size() == 0) {
      return true;
    } else {
      return false;
    }
  }

  public static void main(String[] args) {
    simulation_dquqe sd = new simulation_dquqe();
    Object o1 = new Object();
    Object o2 = new Object();
    Object o3 = new Object();
    sd.put(o1);
    sd.put(o2);
    sd.put(o3);
    System.out.println(sd.arrayList);
    sd.Object_get(1);
    System.out.println(sd.isEmpty());
    sd.arrayList.clear();
    System.out.println(sd.isEmpty());
  }
}
